package ch14;

import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.IOException;

public class _06_FileCopy {
	public static void main(String[] args){
		String dir = _05_FileViewer.class.getResource(".").getPath();
		try{
			FileInputStream fis = new FileInputStream(dir+"_05_input.properties");
			FileOutputStream fos = new FileOutputStream("c:/input.propertes");
			int data = 0;
			while((data=fis.read())!=-1) fos.write(data);
			System.out.println("saved.");
			fis.close();
			fos.close();
		}catch(IOException e){
			e.printStackTrace();
		}
	}
}
